KFbxConstraint Class Reference

#include <kfbxconstraint.h>
Inheritance diagram for KFbxConstraint:
Inheritance graph
[legend]

List of all members.


Detailed Description

Base class for weighted animation constraints.

Constraints are primarily used to impose limits on properties of objects (e.g. position, orientation, scale) and to automate animation processes. A constrained object is an object with properties constrained by one or more weighted constraint sources.

Definition at line 60 of file kfbxconstraint.h.


Error Management

enum   EError {
   eERROR,
   eERROR_COUNT
}
  Error identifiers. More...
KError GetError ()
  Retrieve error object.
EError  GetLastErrorID () const
  Get last error code.
const char *  GetLastErrorString () const
  Get last error string.

Properties

KFbxTypedProperty< fbxDouble1 Weight
  This property represents the degree of influence of a constraint from 0.0 (no influence) to 100.0 (full influence).
KFbxTypedProperty< fbxBool1 Active
  This property controls whether the constraint is applied or not.
KFbxTypedProperty< fbxBool1 Lock
  This property handles the lock state of the constraint.

Public Types

enum   EConstraintType {
   eUNIDENTIFIED,
   ePOSITION,
   eROTATION,
   eSCALE,
   ePARENT,
   eSINGLECHAIN_IK,
   eAIM,
   eCHARACTER_CONSTRAINT,
   eCUSTOM,
   eCONSTRAINT_COUNT
}
  Constraint attribute types. More...

Public Member Functions

virtual EConstraintType  GetConstraintType () const
  Access the type of the constraint.
virtual KFbxObject GetConstrainedObject () const
  Retrieve the constrained object.
virtual int  GetConstraintSourceCount () const
  Retrieve the count of constraint source.
virtual KFbxObject GetConstraintSource (int pIndex) const
  Retrieve a constraint source with the specified index.
virtual void  SetOffset (KFbxVector4 pOffset)
  Set value of the offset.
double  GetSourceWeight (const KFbxObject *pObject) const
  Get the weight associated with a constraint source.
K_DEPRECATED void  SetActive (bool pActive)
  This method is deprecated and should be replaced with Active.Set(active_value).
K_DEPRECATED bool  GetActive () const
  This method is deprecated and should be replaced with active_value = Active.Get().

Member Enumeration Documentation

Constraint attribute types.

  • eUNIDENTIFIED Invalid constraint.
  • ePOSITION Position constraint (referred to as a point constraint in Maya).
  • eROTATION Rotation constraint (referred to as an orient constraint in Maya).
  • eSCALE Scale constraint.
  • ePARENT Parent constraint.
  • eSINGLECHAIN_IK Single chain IK constraint.
  • eAIM Aim constraint.
  • eCHARACTER_CONSTRAINT Character.
  • eCUSTOM Constraint defined by customers.
  • eCONSTRAINT_COUNT The count of constraint type.
Enumerator:
eUNIDENTIFIED 
ePOSITION 
eROTATION 
eSCALE 
ePARENT 
eSINGLECHAIN_IK 
eAIM 
eCHARACTER_CONSTRAINT 
eCUSTOM 
eCONSTRAINT_COUNT 

Definition at line 103 of file kfbxconstraint.h.

enum EError

Error identifiers.

  • eERROR
  • eERROR_COUNT
Enumerator:
eERROR 
eERROR_COUNT 

Reimplemented in KFbxCharacter.

Definition at line 171 of file kfbxconstraint.h.


Member Function Documentation

virtual EConstraintType GetConstraintType (  )  const [inline, virtual]

Access the type of the constraint.

Returns:
This type of the constraint.

Definition at line 120 of file kfbxconstraint.h.

References eUNIDENTIFIED.

virtual KFbxObject* GetConstrainedObject (  )  const [inline, virtual]

Retrieve the constrained object.

Returns:
The constrained object.

Reimplemented in KFbxConstraintAim, KFbxConstraintParent, KFbxConstraintPosition, KFbxConstraintRotation, and KFbxConstraintScale.

Definition at line 125 of file kfbxconstraint.h.

References NULL.

virtual int GetConstraintSourceCount (  )  const [inline, virtual]

Retrieve the count of constraint source.

Returns:
The count of constraint source.

Reimplemented in KFbxConstraintAim, KFbxConstraintParent, KFbxConstraintPosition, KFbxConstraintRotation, and KFbxConstraintScale.

Definition at line 130 of file kfbxconstraint.h.

virtual KFbxObject* GetConstraintSource ( int  pIndex  )  const [inline, virtual]

Retrieve a constraint source with the specified index.

Parameters:
pIndex  The specified index.
Returns:
The constraint source at the specified index.

Reimplemented in KFbxConstraintAim, KFbxConstraintParent, KFbxConstraintPosition, KFbxConstraintRotation, and KFbxConstraintScale.

Definition at line 136 of file kfbxconstraint.h.

References NULL.

virtual void SetOffset ( KFbxVector4  pOffset  )  [virtual]

Set value of the offset.

Parameters:
pOffset  Offset vector value.

Reimplemented in KFbxConstraintAim, KFbxConstraintPosition, KFbxConstraintRotation, and KFbxConstraintScale.

double GetSourceWeight ( const KFbxObject pObject  )  const

Get the weight associated with a constraint source.

Parameters:
pObject  The given constraint source.
Returns:
The weight of the constraint source.

K_DEPRECATED void SetActive ( bool  pActive  ) 

This method is deprecated and should be replaced with Active.Set(active_value).

K_DEPRECATED bool GetActive (  )  const

This method is deprecated and should be replaced with active_value = Active.Get().

KError& GetError (  ) 

Retrieve error object.

Returns:
Reference to error object.

EError GetLastErrorID (  )  const

Get last error code.

Returns:
Last error code.

const char* GetLastErrorString (  )  const

Get last error string.

Returns:
Textual description of the last error.

Member Data Documentation

This property represents the degree of influence of a constraint from 0.0 (no influence) to 100.0 (full influence).

Default value is 100.0.

Definition at line 73 of file kfbxconstraint.h.

This property controls whether the constraint is applied or not.

If the value is false the constraint will have no effect. The default value is true.

Default value is true.

Definition at line 80 of file kfbxconstraint.h.

This property handles the lock state of the constraint.

When enabled, the constrained object cannot be moved away from its constrained location when the constraint is active.

Default value is false.

Definition at line 88 of file kfbxconstraint.h.

KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint
KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint KFbxConstraint